import request from '@/utils/request'

// 查询社区惩罚列表
export function listPunish(query) {
  return request({
    url: '/bbs/punish/list',
    method: 'get',
    params: query
  })
}

// 查询社区惩罚详细
export function getPunish(id) {
  return request({
    url: '/bbs/punish/' + id,
    method: 'get'
  })
}

// 新增社区惩罚
export function addPunish(data) {
  return request({
    url: '/bbs/punish',
    method: 'post',
    data: data
  })
}

// 修改社区惩罚
export function updatePunish(data) {
  return request({
    url: '/bbs/punish',
    method: 'put',
    data: data
  })
}

// 删除社区惩罚
export function delPunish(id) {
  return request({
    url: '/bbs/punish/' + id,
    method: 'delete'
  })
}

// 导出社区惩罚
export function exportPunish(query) {
  return request({
    url: '/bbs/punish/export',
    method: 'get',
    params: query
  })
}

export function isPunish(query){
  return request({
    url: '/bbs/punish/isPunish',
    method: 'get',
    params: query
  })
}